package kkk;

class CPU {
	 int speed;
	 public int getSpeed() {
	     return speed;
	 }
	 public void setSpeed(int k) {
	     this.speed = k;
	 }
	}

	class HardDisk {
	 private int amount; 
	 public int getAmount() {
	     return amount;
	 }
	 public void setAmount(int c) {
	     this.amount = c;
	 }
	}

	class PC {
	 private CPU cpu; 
	 private HardDisk HD; 
	 public void setCPU(CPU c) {
	     this.cpu = c;
	 }
	 public void setHardDisk(HardDisk h) {
	     this.HD = h;
	 }
	 public void show() {
	     System.out.println("CPU Speed: " + cpu.getSpeed() + " MHz");
	     System.out.println("Hard Disk Capacity: " + HD.getAmount() + " GB");
	 }
	}

	public class TEST {
	 public static void main(String[] args) {
	     CPU cpu = new CPU();
	     cpu.setSpeed(2200);

	     HardDisk disk = new HardDisk();
	     disk.setAmount(200);

	     PC pc = new PC();

	     pc.setCPU(cpu);
	     pc.setHardDisk(disk);
	     pc.show();
	 }
	}

